-
Notifications
You must be signed in to change notification settings - Fork 473
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Migrate metadata from setup.py and setup.cfg to pyproject.toml #2517
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to fix our CI tests please which currently call setup.py to install itself.
a2f6342
to
0bc11c1
Compare
Yes. These calls to This pull request must |
0bc11c1
to
594a0cf
Compare
Makefile
Outdated
python setup.py check --restructuredtext --strict | ||
echo "WARNING: 'make check-distutils' is disabled!!" | ||
# python setup.py check --restructuredtext --strict |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just adding a comment here to make sure we don't miss this, it will obviously be outdated when someone fixes it.
So in the same way as you changed the other commands, how do we run this command in the new format? If you can tell me on the command line, I should be able to make it work in the Makefile, i.e. I think it's a Python not a Make issue.
This page explains what it did, the correct answer might be that these particular commands are no longer required, but hopefully there's a similar set of tools to validate pyproject.toml we should switch to instead? It's interesting that we weren't validating the metadata itself before!
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Ahhh... I did not know that setup.py
had a check
command. The commit message mentions validate-pyproject
.
I will update.
594a0cf
to
e7ed1dc
Compare
Co-authored-by: Peter Newman <[email protected]>
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@@ -47,8 +47,8 @@ trim-dictionaries: | |||
check-manifest: | |||
check-manifest | |||
|
|||
check-distutils: | |||
python setup.py check --restructuredtext --strict | |||
check-pyproject: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
May as well leave some backwards compatibility...
check-pyproject: | |
check-distutils: check-pyproject | |
check-pyproject: |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
distutils
will not be in py1.12 so this is probably a good time to change the name.
@@ -2,11 +2,11 @@ SORT_ARGS := -f -b | |||
|
|||
DICTIONARIES := codespell_lib/data/dictionary*.txt | |||
|
|||
PHONY := all check check-dictionaries sort-dictionaries trim-dictionaries check-dictionary sort-dictionary trim-dictionary check-manifest check-distutils flake8 pytest pypi clean | |||
PHONY := all check check-dictionaries sort-dictionaries trim-dictionaries check-dictionary sort-dictionary trim-dictionary check-manifest check-pyproject flake8 pytest pypi clean |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
PHONY := all check check-dictionaries sort-dictionaries trim-dictionaries check-dictionary sort-dictionary trim-dictionary check-manifest check-pyproject flake8 pytest pypi clean | |
PHONY := all check check-dictionaries sort-dictionaries trim-dictionaries check-dictionary sort-dictionary trim-dictionary check-manifest check-pyproject check-distutils flake8 pytest pypi clean |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This would run the code twice under two different names.
Argh sorry I didn't see this! #2523 also has CI infrastructure to make releasing (hopefully!) trivial, so I'd rather merge that one. |
No troubles. Closing in favor of #2523. |
Migrate to
pyproject.toml
usingini2toml
to do the file conversion and runningvalidate-pyproject
to validate the results.flake8
is yet not compatible withpyproject.toml
so move its config into.flake8